﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Index.aspx.cs" Inherits="VisualAgile.Web.Views.Create.Index" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    
    <link rel="shortcut icon" href="../../Content/icons/Icon.ico" type="image/x-icon" />
    
    <link href="../../Content/fonts-min.css" rel="stylesheet" type="text/css"></link>

    <script id="js/Ext.ux.Util.js" src="../../Content/js/Ext.ux.Util.js" type="text/javascript"></script>

    <script src="../../Content/ColorField/color-field.js" type="text/javascript"></script>

    <link href="../../Content/ColorField/color-field.css" rel="stylesheet" type="text/css"></link> 
    
    <script type="text/javascript" src="../../Scripts/Ext.ux.form.CodeField.js"></script>
    
    <script type="text/javascript" src="../../Scripts/Ext.ux.guid.grid.PropertyGrid.js"></script>

    <script src="../../Content/js/Ext.ux.ComponentCollection.js" type="text/javascript"></script>    
    
    <script src="../../Content/js/Extx.cmp.workSpace.js" type="text/javascript"></script>    
  
    <script type="text/javascript" src="../../Scripts/addEntryWindow.js"></script>

    <script type="text/javascript" src="../../Scripts/calendarWindow.js"></script>
    
    <script type="text/javascript" src="../../Scripts/Ext.ux.ToastWindow.js"></script>
    
    <script type="text/javascript" src="../../Scripts/message.js"></script>
    
    <script type="text/javascript" src="../../Scripts/line.js"></script>

    <script type="text/javascript" src="../../Scripts/wz_jsgraphics.js"></script>
    
    <script type="text/javascript" src="../../Scripts/index.js"></script>

    <title> <%= Html.Encode(ViewData["Title"]) %></title>
           
    <STYLE type="text/css">
        
        .x-date-middle {

            padding-top:2px;padding-bottom:2px;

            width:130px; /* FF3 */

        } 
        
        #helpQuestionWrapper ul{
			margin-left:30px;
		}
		#helpQuestionWrapper ul li{
			list-style-type:circle;
			font-size:0.9em;
			margin-bottom:5px;
		}
		#helpAnswersWrapper p{
			margin-bottom:20px;
		}		
    </STYLE>

</head>
<body>
    <div id="loading-mask">
    </div>
    <div id="loading">
        <div class="loading-indicator">
            <img src="../../Content/images/icons/loading-balls.gif" style="margin-right: 8px;"
                align="absmiddle" />Loading
            <%=ViewData["Title"]%>....</div>
    </div>    
    <mvc:ExtScriptManager ID="ExtScriptManager" runat="server" />  
    <mvc:ExtJSON ID="workPlace" runat="server">
        <component>
            <mvc:ExtViewport ID="portal" layout="border" runat="server">
                <items>
                    <mvc:ExtPanel ID="toolbox" runat="server" minSize="175" maxSize="175" border="false"
                        margins="5 0 5 5" split="true" autoScroll="true" Width="220" title="Project Explorer"
                        cmargins="5 5 5 5" region="west" layout="border" frame="false" collapsible="true">
                        <items>
                            <mvc:ExtPanel ID="pnlBD" region="center" border="false" frame="false" runat="server"
                                xtype="panel">
                                <items>
                                    <mvc:ExtWindow bodyStyle="padding:10px;" ID="extWindow" title="Window Example" Height="220"
                                        Width="300" runat="server">
                                    </mvc:ExtWindow>
                                    <mvc:ExtPanel ID="DailyBurndownPnl" bodyStyle="padding-top:5px;" title="Iteration Burndown"
                                        Height="175" border="false" frame="false" runat="server" xtype="panel">
                                        <html>
                                        <div id="dailyBurndownGraph" title="Double click to enlarge" ondblclick="javascript:showBurndown(this)"
                                            style="overflow: hidden; position: relative; height: 100%; width: 220px;">
                                        </div>

                                        <script type="text/javascript">
                                            function showBurndown(that) {
                                                if (that.innerHTML == "") return;
                                                var designerCmp = Ext.getCmp('ProjectTabPanel').activeTab.items.items[0].plugins[0];

                                                designerCmp.loadBurndown(Ext.getCmp('ProjectTabPanel').activeTab, null, true);
                                            }
                                        </script>

                                        </html>
                                    </mvc:ExtPanel>
                                    <mvc:ExtPanel ID="ReleaseBurndownPnl" Height="175" title="Release Burndown" border="false"
                                        frame="false" runat="server" xtype="panel">
                                        <html>
                                        <div id="releaseBurndownGraph" title="Double click to enlarge" ondblclick="javascript:showReleaseBurndown(this)"  style="overflow: hidden; position: relative; height: 100%;
                                            width: 220px;">
                                        </div>
                                        <script type="text/javascript">
                                            function showReleaseBurndown(that) {
                                                if (that.innerHTML == "") return;
                                                var designerCmp = Ext.getCmp('ProjectTabPanel').activeTab.items.items[0].plugins[0];

                                                designerCmp.loadReleaseBurndown(Ext.getCmp('ProjectTabPanel').activeTab, null, true);
                                            }
                                        </script>
                                        </html>
                                    </mvc:ExtPanel>
                                </items>
                            </mvc:ExtPanel>
                            <mvc:ExtPanel ID="proGrid" disabled="true" xtype="guidpropertygrid" runat="server"
                                region="south" border="false" split="true" Height="220">
                            </mvc:ExtPanel>
                        </items>
                    </mvc:ExtPanel>
                    <mvc:ExtPanel ID="helpPanel" runat="server" minSize="175" maxSize="400"
                        border="true" margins="5 0 5 5" layout="fit" split="true" autoScroll="true" Width="300"
                        title="<img src=../../Content/images/help.png align=left /> Help" cmargins="5 5 5 5" region="east" collapsible="true" collapsed="true">
                        <items>
                            <mvc:ExtPanel ID="pnlHelpCont" runat="server" bodyStyle="padding:20px;background:transparent url(../../Content/images/grass.gif) bottom repeat-x;" frame="false" border="false">
                            </mvc:ExtPanel>
                        </items>
                        <script>
                            "expand": function(cmp){
					            var innerCmp = cmp.findByType("panel")[0];
					            innerCmp.getUpdater().un("update", helpUpdaterSetEvents, innerCmp, innerCmp);
					            innerCmp.getUpdater().on("update", helpUpdaterSetEvents, innerCmp, innerCmp);
					            if (!cmp.hasLoaded){
						            cmp.hasLoaded = true;
						            innerCmp.load({
							            url: "../Help/Help/?r=" + Math.random()
						            });
					            }
				            }
                        </script>
                    </mvc:ExtPanel>
                    <mvc:ExtTabPanel activeTab="0" deferredRender="true" runat="server" ID="ProjectTabPanel"
                        border="false" region="center">
                        <items>
                            <mvc:ExtPanel xtype="panel" layout="fit" title="Console" ID="ProjectPanel" runat="server">
                                <script>
                                    activate: function(el) {
                                        var obj = Ext.getCmp('ProjectPanel').items;
                                        if(obj && obj.items.length > 0) {
                                            Ext.getCmp('ProjectPanel').items.clear();
                                            designer = addDesigner('ProjectPanel', 'Project', 'Project', { projectId: Ext.get('projectId').dom.value });
                                        }
                                    },
                                    deactivate: function() {
                                        var designerCmp = this.items.items[0].items.items[0].plugins[0];
                                        designerCmp.activeElement = false;
                                        
                                        if (designerCmp.propertyGrid) {
                                            designerCmp.propertyGrid.disable();
                                            designerCmp.propertyGrid.setSource({});
                                        }

                                        //Remove old highlight and drag support                                            
                                    }
                                </script>
                            </mvc:ExtPanel>
                        </items>
                    </mvc:ExtTabPanel>
                    <mvc:ExtPanel ID="northPnl" runat="server" frame="false" minSize="175" maxSize="400"
                        border="false" margins="5 0 5 5" layout="fit" split="false" bodyStyle="padding-top:8px;background:#f4f7fc url(../../Content/images/blue-grad-sm.png) bottom repeat-x;"
                        autoScroll="true" Height="40" cmargins="5 5 5 5" region="north">
                        <html>
                        <div id="loginDiv" style="display:none;" >
                            <% if (ViewData["Users"] != null)
                               {%>
                                <label for="users"><h3>&nbsp;&nbsp;User</h3></label>&nbsp;
                                <%= Html.DropDownList("users", (IEnumerable<SelectListItem>)ViewData["Users"])%>
                            <%} %>
                            <label for="password"><h3>&nbsp;&nbsp;Password</h3></label>&nbsp;
                            <%= Html.Password("password","", (object)new { @class = "txtSize", @onkeypress = "authenticateFn(event)" })%>
                            <script language="javascript">
                                function authenticateFn(event) {
                                        var charCode;
                                        if(event && event.which) {
                                            var e = event;
                                            charCode = e.which;
                                        } else {
                                            var e = window.event;
                                           charCode =e.keyCode;
                                       }
                                       var name;
                                       (Ext.get('users')) ? name = Ext.get('users').dom[Ext.get('users').dom.selectedIndex].value : name = null;
                                       
                                        if (charCode == 13) {
                                            Ext.Ajax.request({
                                                url: '../Login/Authenticate',
                                                method: 'POST',
                                                params: {
                                                    "project": Ext.get('projectId').dom.value,
                                                    "name": name,
                                                    "password": (Ext.get('password').dom.value == "") ? null : Ext.get('password').dom.value
                                                }, // the unique id(s)
                                                callback: function(options, success, response) {
                                                    if (success) {                                                        
                                                        var result = Ext.util.JSON.decode(response.responseText);
                                                        if (result.Result) {
                                                            Ext.getCmp('ProjectTabPanel').show();
                                                            Ext.getCmp('helpPanel').show();
                                                            Ext.getCmp('toolbox').show();
                                                            Ext.getCmp('northPnl').show();
                                                            loginWindow.remove();
                                                            designer = addDesigner('ProjectPanel', 'Project', 'Project', { projectId: Ext.get('projectId').dom.value });
                                                        } else {
                                                            alert(result.Message);
                                                        }
                                                    } else {                                                        
                                                        alert(response.responseText);
                                                    }
                                                }                                                
                                            });// end Ajax request
                                        }                               
                                }
                            </script>
                        </div>
                        <input type="hidden" id="hdnUser" name="hdnUser" value='<%= ViewData["currentUser"]%>' />
                        <input type="hidden" id="authenticate" name="authenticate" value='<%= ViewData["authenticate"]%>' />
                        <input type="hidden" id="projectId" name="projectId" value='<%= ViewData["projectId"]%>' />
                        <input type="hidden" id="allowDefaults" name="allowDefaults" value='<%= ViewData["allowDefaults"]%>' />
                        <div id="divProject" class="project-name">&nbsp;
                            <%=ViewData["Title"]%></div>
                        <div style='position: absolute; right: 5px; top: 0px;'><form action="/Login/Logout" method="post" >
                            <input disabled class="x-btn button" id="calWinLink" type="button" value="&nbsp;&nbsp;Smiley Calendar&nbsp;&nbsp;" />                                                  
                            <input class="x-btn" id="reportBug" type="button" value="&nbsp;&nbsp;Report a bug&nbsp;&nbsp;" />
                            <input disabled class="x-btn button" id="helpPanelOpen" type="button" value="&nbsp;&nbsp;Help&nbsp;&nbsp;" />
                            <input disabled class="x-btn button" id="headerSettingsLink" type="button" value="&nbsp;&nbsp;Settings&nbsp;&nbsp;" />
                            <input disabled='<%if (ViewData["authenticate"] != null) { %><%=!(bool)ViewData["authenticate"]%><%} %>' class="x-btn button" id="logout" type="submit" value="&nbsp;&nbsp;Logout&nbsp;&nbsp;" /></form>
                        </div>
                        </html>                       
                    </mvc:ExtPanel>
                </items>
            </mvc:ExtViewport>
        </component>
    </mvc:ExtJSON>
    <mvc:ExtOnReady ID="onReady1" runat="server">

        <script>

            Ext.get('ExtGridPanel1').dom.style.display = 'none';

            workPlace.prototype = {

                load: function() {

                    var elId = new Date();

                    var projectId = Ext.get('projectId').dom.value;
                    var projectTabPanel = Ext.getCmp('ProjectTabPanel');

                    /*
                    You can now use the designer as panel, JSON can contain javascript and information
                    of base info is stored in special tag Window. enabling auto create window/frame see show code
                    */
                    var cookies = new Ext.state.CookieProvider();
                    var options = cookies.get('Designer.Options') ||
                      { dock: 1,
                          compressed: 0,
                          codepress: 1,
                          autoresize: 1,
                          floatheight: 480,
                          floatwidth: 580,
                          cmpfiles: "{0}ThirdParty.Components.json"
                      };

                    //Url based actions
                    var windowMode = Ext.ux.UTIL.getUrlAction('window', options.float) == 0; //Change this flag to true if you want designer to be a window
                    var docked = Ext.ux.UTIL.getUrlAction('docked', options.dock) == 1;
                    var nocache = Ext.ux.UTIL.getUrlAction('nocache', options.nocache) == 1;
                    var autoResize = Ext.ux.UTIL.getUrlAction('autoresize', options.autoresize) == 1;
                    var cmpfiles = (options.cmpfiles || "").replace('\r').split("\n");

                    require('Ext.ux.guid.plugin.Designer.css;Ext.ux.Override;' +
		                    'Ext.ux.CodePress.js;Ext.ux.ComponentCollection;Ext.ux.Json;' +
		                    'Ext.ux.form.CodeField;Ext.ux.data.HttpMergeProxy;Ext.ux.JsonPanel;' +
		                    'Ext.ux.JsonWindow;Ext.ux.guid.tree.JsonTreeLoader;' +
		                    'Ext.ux.guid.tree.CodeLoader;Ext.ux.guid.grid.PropertyGrid;' +
		                    'Ext.ux.guid.data.Repository;Ext.ux.guid.tree.RepositoryLoader;' +
		                    'Ext.ux.guid.data.CookieRepository;Ext.ux.guid.data.PHPFileRepository;' +
		                    'Ext.ux.guid.plugin.Designer',
	                        { basedir: '../../Content/js', cssdir: '../../Content/css', nocache: nocache });
                    Extx.cmp.msg("", "", true);
                    Extx.cmp.oopsMsg("", "", true);

                    if (Ext.get('authenticate').dom.value.toLowerCase() == "true") {
                        Ext.getCmp('ProjectTabPanel').hide();
                        Ext.getCmp('toolbox').hide();
                        Ext.getCmp('helpPanel').hide();
                        Ext.getCmp('northPnl').hide();
                        var obj = Ext.get('loginDiv').dom;
                        var html = obj.innerHTML;
                        obj.parentNode.removeChild(obj);
                        Extx.cmp.loginWin("login", "", true);
                        Extx.cmp.loginWin("login", html);
                    } else {
                        designer = addDesigner('ProjectPanel', 'Project', 'Project', { projectId: Ext.get('projectId').dom.value });
                        Ext.getCmp('proGrid').getProperties();                        
                    }
                }
            }

            new workPlace().load();

            setTimeout(function() {
                Ext.get('loading').hide();
                Ext.get('loading-mask').fadeOut({
                    remove: true
                });
            }, 500);                        
        </script>

    </mvc:ExtOnReady>
    <mvc:ExtJSON ID="settingCfgs" runat="server">
        <xtype>
            <mvc:ExtItem modal="true" layout="border" width="600" title="Settings" height="500">
                <items>
                    <mvc:ExtItem xtype="tabpanel" deferredRender="false" region="center" enableTabScroll="true"
                        anchor="100% 0" activeTab="0" frame="false" border="false">
                        <items>
                           <mvc:ExtItem xtype="panel" title="Project" frame="false" border="false" autoScroll="true"
                                anchor="100%" bodyStyle="padding:20px">
                                <items>
                                    <mvc:ExtItem xtype="form" layout="form" id="frmAccount" labelWidth="130" defaultType="textfield"
                                        frame="false" border="false" autoScroll="true">
                                        <defaults>
                                            <mvc:ConfigItem name="width" value="100%" />
                                        </defaults>
                                        <items>
                                            <mvc:ExtItem fieldLabel="Old Password" id="OldPassword" name="OldPassword" allowBlank="true" inputType="password">
                                            </mvc:ExtItem>
                                            <mvc:ExtItem fieldLabel="New Password" id="NewPassword" name="NewPassword" allowBlank="true"
                                                inputType="password">
                                            </mvc:ExtItem>                                           
                                        </items>
                                    </mvc:ExtItem>
                                </items>
                            </mvc:ExtItem>                            
                            <mvc:ExtItem xtype="panel" title="Team" frame="false" border="false" autoScroll="true"
                                anchor="100%" bodyStyle="padding:20px">      
                                <listeners>
                                    <script>
                                        activate: function() { Ext.get('ExtGridPanel1').dom.style.display = 'block'; }
                                    </script>
                                </listeners>                          
                                <items>
                                    <mvc:ExtItem xtype="form" layout="form" id="ExtJSItem1" labelWidth="130" defaultType="textfield"
                                        frame="false" border="false" autoScroll="true">
                                        <defaults>
                                            <mvc:ConfigItem name="width" value="100%" />
                                        </defaults>
                                        <html>
                                        <mvc:ExtGridPanel ID="ExtGridPanel1" renderTo="ExtGridPanel1" Width="545" Height="250"
                                            autoHeight="true" loadMask="true" runat="server">                                            
                                            <store>
                                                <mvc:ExtStore>                                                    
                                                    <sortInfo field="Name" direction="DESC" />
                                                    <proxy>
                                                        <mvc:ExtHttpProxy url="/User/GetAll" />
                                                    </proxy>
                                                    <reader>
                                                        <mvc:ExtJsonReader id="UserID" root="users">
                                                            <fields>
                                                                <mvc:ExtRecord name="UserID" />
                                                                <mvc:ExtRecord name="Role" />
                                                                <mvc:ExtRecord name="Name" />
                                                                <mvc:ExtRecord name="Email" />
                                                                <mvc:ExtRecord name="Mobile" />
                                                                <mvc:ExtRecord name="Telephone" />
                                                            </fields>
                                                        </mvc:ExtJsonReader>
                                                    </reader>
                                                </mvc:ExtStore>
                                            </store>
                                            <cm>
                                                <mvc:ExtColumn header="UserName" dataIndex="Name" />
                                                <mvc:ExtColumn header="Email" width="150" dataIndex="Email" />
                                                <mvc:ExtColumn header="Mobile" dataIndex="Mobile" />
                                                <mvc:ExtColumn header="Telephone" dataIndex="Telephone" />
                                                <mvc:ExtColumn header="Role" dataIndex="Role" />
                                            </cm>
                                            <selModel>
                                                <mvc:ExtRowSelectionModel singleSelect="true" />
                                            </selModel>
                                        </mvc:ExtGridPanel>
                                        </html>
                                        <defaults>
                                            <mvc:ConfigItem name="width" value="100%" />
                                        </defaults>
                                        <items>
                                            <mvc:ExtItem fieldLabel="Name" name="Name" allowBlank="false">
                                            </mvc:ExtItem>
                                            <mvc:ExtItem fieldLabel="Email" vtype="email" vtypeText="Please Enter a Valid Email Address."
                                                name="Email" allowBlank="false">
                                            </mvc:ExtItem>
                                            <mvc:ExtItem fieldLabel="Mobile" name="Mobile" allowBlank="true">
                                            </mvc:ExtItem>
                                            <mvc:ExtItem fieldLabel="Telephone" name="Telephone" allowBlank="true">                                                
                                            </mvc:ExtItem>
                                            <mvc:ExtItem id="Role" name="Role" xtype="combo" hiddenName="RoleID" valueField="value" triggerAction="All" fieldLabel="Role" displayField="text"
                                            mode="Local">                                                                                                                   
                                                <simpleStore>
                                                    <fields>
                                                        <mvc:ExtRecord name="value" />
                                                        <mvc:ExtRecord name="text" />
                                                    </fields>
                                                    <data>
                                                        [['1', 'Manager'],['2', 'Lead Developer'],['3', 'Developer']]
                                                    </data>
                                                </simpleStore>
                                            </mvc:ExtItem>                  
                                            <mvc:ExtItem xtype="panel" border="false" frame="false" name="telephone">
                                                <buttons>
                                                    <mvc:ExtItem xtype="button" text="Add" name="telephone" allowBlank="false">
                                                        <handler>

                                                            <script>
                                                                function AddRecord(btn) {
                                                                    
                                                                    var UserForm = getSetCmps().frmTeam.getForm();
                                                                    if (UserForm.isValid()) {
                                                                        btn.disabled = true;
                                                                        Ext.MessageBox.show({
                                                                            msg: 'Adding user, please wait',
                                                                            progressText: 'Added user is',
                                                                            width: 300,
                                                                            wait: true,
                                                                            waitConfig: {
                                                                                interval: 200
                                                                            }
                                                                        });
                                                                        var formvalue = UserForm.getValues();

                                                                        Ext.Ajax.request({
                                                                            url: '../User/AddUser',
                                                                            method: 'POST',
                                                                            params: { User: Ext.util.JSON.encode(formvalue) },
                                                                            callback: function(options, success, response) {
                                                                                if (success) {
                                                                                    Ext.MessageBox.hide();
                                                                                    var result = Ext.util.JSON.decode(response.responseText)
                                                                                    //Ext.MessageBox.alert("Message", result.Message);
                                                                                } else {
                                                                                    Ext.MessageBox.hide();
                                                                                    Ext.MessageBox.alert("Failure, please try again", response.responseText);
                                                                                }
                                                                            },
                                                                            // the function to be called upon failure of the request
                                                                            // (server script, 404, or 403 errors)
                                                                            failure: function(response, options) {
                                                                                Ext.MessageBox.hide();
                                                                                ReturnValue = Ext.MessageBox.alert("Warning, There was an unexpected error! Please contact administrator！");
                                                                            },
                                                                            success: function(response, options) {
                                                                                Ext.MessageBox.hide();
                                                                                getSetCmps().grdUsers.store.reload();
                                                                            }
                                                                        })// end Ajax request

                                                                    }
                                                                }
                                                            </script>

                                                        </handler>
                                                    </mvc:ExtItem>
                                                    <mvc:ExtItem xtype="button" text="Remove" name="telephone" allowBlank="false">
                                                        <handler>

                                                            <script>
                                                                function handleDelete() {

                                                                    var selectedKeys = getSetCmps().grdUsers.selModel.selections.keys; // returns
                                                                    // array of
                                                                    // selected
                                                                    // rows ids
                                                                    // only
                                                                    if (selectedKeys.length > 0) {
                                                                        Ext.MessageBox.confirm('Message', 'Are you sure you want to delete the record you selected？', deleteRecord);
                                                                    } else {
                                                                        Ext.MessageBox.alert('Message', 'Please select the record！');
                                                                    } // end
                                                                }                                                           
                                                            </script>

                                                        </handler>
                                                    </mvc:ExtItem>
                                                </buttons>
                                            </mvc:ExtItem>
                                        </items>
                                    </mvc:ExtItem>
                                </items>
                            </mvc:ExtItem>
                        </items>
                    </mvc:ExtItem>
                </items>
                <buttons>
                    <mvc:ExtItem text="Save">
                        <handler>

                            <script>
                                function() { 
                                    //var params = { method: "saveUserAccountSettings" };
                                    var frmAccData = Ext.encode(getCmps().frmAccount.getForm().getValues());                                                                        
                                    Ext.Ajax.request({
                                        url: '../User/ChangePassword',
                                        params: Ext.decode(frmAccData),
                                        success: (function(response, options) {
                                            settingsWin.hide();
                                            Ext.MessageBox.hide();
                                            var response = Ext.decode(response.responseText);
                                            var cmps = getCmps();
                                            if (!response.Result) {
                                                Ext.Msg.alert("Update failed", response.Message);
                                            }
                                            else {
                                                getCmps().frmop.setValue("");
                                                getCmps().frmnp.setValue("");
                                                getCmps().frmAccount.getForm().clearInvalid();                                                
                                            }
                                        }),
                                        failure: (function(response) { Ext.MessageBox.hide(); Ext.Msg.alert("Communication error", response.responseText); })
                                    });
                                }
                            </script>

                        </handler>
                    </mvc:ExtItem>
                    <mvc:ExtItem text="Cancel">
                        <handler>

                            <script>
                                function() { Ext.getCmp('proGrid').getProperties(); settingsWin.hide(); }
                            </script>

                        </handler>
                    </mvc:ExtItem>
                </buttons>
                <listeners>

                    <script>
                        "show": function(cmp){
			                    }
                    </script>

                </listeners>
            </mvc:ExtItem>
        </xtype>

        <script>
            Ext.namespace("dlr.cmp.workSpace");
            dlr.cmp.workSpace.settingsWindow = function(cfg) {
                var that = this;
                var windowCfg = settingCfgs;
                var ldMsk = null;

                Ext.getCmp('ExtGridPanel1').store.load();

                // ------------------------------------------------
                // public properties
                // ------------------------------------------------
                // ------------------------------------------------
                // public methods
                // ------------------------------------------------
                // ------------------------------------------------
                // constructor code
                // ------------------------------------------------
                Ext.apply(this, cfg);
                // apply private cfgs
                Ext.apply(this, windowCfg);
                dlr.cmp.workSpace.settingsWindow.superclass.constructor.call(this, cfg);
                // events
            };
            Ext.extend(dlr.cmp.workSpace.settingsWindow, Ext.Window);
            Ext.reg("settingsWindow", dlr.cmp.workSpace.settingsWindow);
        </script>
 
    </mvc:ExtJSON>       
</body>
</html>
